package cn.datax.service.data.market.service;

import cn.datax.common.base.BaseService;
import cn.datax.service.data.market.api.dto.ApiWarnRuleDto;
import cn.datax.service.data.market.api.dto.DataApiDto;
import cn.datax.service.data.market.api.entity.ApiWarnRuleEntity;
import cn.datax.service.data.market.api.entity.DataApiEntity;
import cn.datax.service.data.market.cata.dto.CataDto;
import cn.datax.service.data.market.cata.dto.CataResourceRelaDto;
import cn.datax.service.data.market.cata.entity.CataEntity;
import cn.datax.service.data.market.cata.entity.CataResourceRelaEntity;
import cn.datax.service.data.market.cata.entity.ResourceInfoEntity;
import cn.datax.service.data.market.cata.entity.UserResourceInfoEntity;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;

import java.util.List;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author yuwei
 * @since 2019-09-04
 */
public interface CataResourceService extends BaseService<CataResourceRelaEntity> {

    int saveRelation(CataResourceRelaDto relaDto);

    void updateRelation(CataResourceRelaDto relaDto);

    List<ResourceInfoEntity> getRelationByCataId(String cataId);

    List<ResourceInfoEntity> getResourceByCataId(String cataId,String resourcrType);

    IPage<ResourceInfoEntity> pageGetResourceByCataId(Page tPage, String cataId, String resourcrType, String resourceName);

    void deleteRelationById(String id);

    int getCataResourceCount(String cataId);

}
